package review;

import java.util.Scanner;

public class Zhishu {

	public static void main(String[] args) {
		Scanner in = new Scanner(System.in);
		System.out.println("输入数字");
		int k = in.nextInt();

		for (int i = 2; i * i <= k; i++) {
			if (k % i == 0) {
				System.out.println(k + " 不是质数");
				return;
			}
		}

		System.out.println(k + "是质数");

	}

}
